package com.vacuela.phonecredits;

import com.u2d.list.RelationalList;
import com.u2d.model.AbstractComplexEObject;
import com.u2d.model.Title;
import com.u2d.type.atom.StringEO;
import java.awt.Color;
//import javax.persistence.Entity;

//@Entity
public class Location extends AbstractComplexEObject{
   private final StringEO _locationName = new StringEO();
   
   private final StringEO _description = new StringEO();
   public static String[] identities = {"_locationName"};
   private final RelationalList _phones = new RelationalList(PhoneProfile.class);
   public static final Class phonesType = PhoneProfile.class;
   public static String phonesInverseFieldName ="location";
   public static String[] fieldOrder =   {"locationName", "description"};
    public static Color colorCode = new Color(0x6169aa);
   
   public Location() {}
   public Location(String location){
      _locationName.setValue(location);
   }
   
   public StringEO getLocationName() { return _locationName; }   
   public StringEO getDescription() {return _description;}
   public RelationalList getPhones(){return _phones; }
    public Title title() {
        
        return _locationName.title().append(_description);
        
    }
}
